#include<iostream>
using namespace std;

int main(){
	int n;
	char c;
	cin>>n>>c;
	int len=(n+1)>>1;
	for(int i=0;i<n;i++)cout<<c;
	cout<<endl;
	for(int i=1;i<len-1;i++){
		cout<<c;
		for(int j=1;j<n-1;j++)cout<<" ";
		cout<<c<<endl;;
	}
	for(int i=0;i<n;i++)cout<<c;
}